<html>
<head><meta charset="utf-8"><title>effect on firefox · t-compiler/wg-parallel-rustc · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/index.html">t-compiler/wg-parallel-rustc</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html">effect on firefox</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="166160893"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166160893" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166160893">(May 21 2019 at 10:44)</a>:</h4>
<p>Hey <span class="user-mention" data-user-id="124287">@mw</span> -- how hard would it be to test the effectiveness of the parallel stuff on building FF? Say on one of the "standard" 14-core desktops?</p>



<a name="166160897"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166160897" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166160897">(May 21 2019 at 10:44)</a>:</h4>
<p>There is some debate about how useful it will be</p>



<a name="166160901"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166160901" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166160901">(May 21 2019 at 10:44)</a>:</h4>
<p>It seems like we could get some preliminary information in that regard</p>



<a name="166160945"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166160945" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166160945">(May 21 2019 at 10:45)</a>:</h4>
<p>Seems like we would have to build a custom version of Rust and then use it in the FF building script somehow?</p>



<a name="166162666"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166162666" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166162666">(May 21 2019 at 11:17)</a>:</h4>
<p>doing a local build with a custom <code>rustc</code> is straightforward (i.e. it uses whatever rustc in on the PATH)</p>



<a name="166162677"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166162677" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166162677">(May 21 2019 at 11:17)</a>:</h4>
<p>I don't have the standard 14-core desktop</p>



<a name="166162725"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166162725" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166162725">(May 21 2019 at 11:18)</a>:</h4>
<p>but I could do a test on my 10-core machine</p>



<a name="166162765"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166162765" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166162765">(May 21 2019 at 11:19)</a>:</h4>
<p>suspect that it won't be much faster (if at all) for the same reasons that pipelining doesn't seem to make much of a difference</p>



<a name="166162790"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166162790" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166162790">(May 21 2019 at 11:19)</a>:</h4>
<p>i.e. all cores are busy compiling small crates or small C++ files</p>



<a name="166163004"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166163004" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166163004">(May 21 2019 at 11:22)</a>:</h4>
<p><span class="user-mention" data-user-id="124287">@mw</span> likely true, it would be good to validate that hypothesis</p>



<a name="166164813"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166164813" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166164813">(May 21 2019 at 11:51)</a>:</h4>
<p>I'll look into it</p>



<a name="166170760"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166170760" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166170760">(May 21 2019 at 13:14)</a>:</h4>
<p>I think that's plausible but rustc did have some gain fwiw</p>



<a name="166170772"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166170772" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166170772">(May 21 2019 at 13:14)</a>:</h4>
<p>(Apparently my old benchmarks were wrong)</p>



<a name="166171059"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166171059" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166171059">(May 21 2019 at 13:18)</a>:</h4>
<blockquote>
<p>(Apparently my old benchmarks were wrong)</p>
</blockquote>
<p>Oh?</p>



<a name="166171657"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166171657" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166171657">(May 21 2019 at 13:25)</a>:</h4>
<p>Yeah, see last row in the spreadsheet -- <a href="https://docs.google.com/spreadsheets/d/1vadQWQQqTODU1_cAENnUjLyXM6cxms-tiCf2kCiNGGM/edit#gid=0&amp;range=26:26" target="_blank" title="https://docs.google.com/spreadsheets/d/1vadQWQQqTODU1_cAENnUjLyXM6cxms-tiCf2kCiNGGM/edit#gid=0&amp;range=26:26">https://docs.google.com/spreadsheets/d/1vadQWQQqTODU1_cAENnUjLyXM6cxms-tiCf2kCiNGGM/edit#gid=0&amp;range=26:26</a></p>



<a name="166171664"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166171664" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166171664">(May 21 2019 at 13:25)</a>:</h4>
<p>rustc-opt   438.81  432.23  389.37      -6.59   -49.44      -1.50%  -11.27%</p>



<a name="166171686"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166171686" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166171686">(May 21 2019 at 13:26)</a>:</h4>
<p>so we see about 11% crate graph (i.e., x.py build --stage 0) speed up with 2 threads</p>



<a name="166174468"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166174468" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166174468">(May 21 2019 at 13:57)</a>:</h4>
<p>bootstrapping parallel rustc takes forever right now</p>



<a name="166174659"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166174659" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166174659">(May 21 2019 at 13:59)</a>:</h4>
<p>I do think those numbers are for regular rustc, just bootstrapped by a parallel compiler</p>



<a name="166174677"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166174677" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166174677">(May 21 2019 at 13:59)</a>:</h4>
<p>Not sure.</p>



<a name="166175020"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166175020" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166175020">(May 21 2019 at 14:02)</a>:</h4>
<p>I'm trying to build a parallel compiler for testing and it's been stuck at libsyntax for an hour or so</p>



<a name="166175023"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166175023" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166175023">(May 21 2019 at 14:02)</a>:</h4>
<p><a href="https://github.com/rust-lang/rust/pull/60035#issuecomment-494001207" target="_blank" title="https://github.com/rust-lang/rust/pull/60035#issuecomment-494001207">https://github.com/rust-lang/rust/pull/60035#issuecomment-494001207</a></p>



<a name="166175071"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166175071" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166175071">(May 21 2019 at 14:02)</a>:</h4>
<p>which is what <span class="user-mention" data-user-id="116466">@Zoxc</span> is probably taking about in the above comment</p>



<a name="166175630"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166175630" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lwshang <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166175630">(May 21 2019 at 14:08)</a>:</h4>
<p>I encounter the same issue that stuck at libsyntax. It never completes. I let it compile overnight but no progress after libsyntax.</p>



<a name="166175647"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166175647" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166175647">(May 21 2019 at 14:08)</a>:</h4>
<p>that seems worrisome</p>



<a name="166178918"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166178918" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166178918">(May 21 2019 at 14:43)</a>:</h4>
<p>I think that's a recent thing</p>



<a name="166178937"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166178937" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166178937">(May 21 2019 at 14:43)</a>:</h4>
<p>I know for sure I've compiled with parallel enabled and not really seen any change in bootstrap time before</p>



<a name="166184325"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166184325" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Zoxc <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166184325">(May 21 2019 at 15:43)</a>:</h4>
<p>The lack of caching in <a href="https://github.com/rust-lang/rust/pull/60444" target="_blank" title="https://github.com/rust-lang/rust/pull/60444">https://github.com/rust-lang/rust/pull/60444</a> is causing compiling syntax to take very long or looping forever.</p>



<a name="166196286"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166196286" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Zoxc <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166196286">(May 21 2019 at 17:58)</a>:</h4>
<p>This happens when building with a non-parallel compiler too</p>



<a name="166204170"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166204170" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lwshang <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166204170">(May 21 2019 at 19:24)</a>:</h4>
<p>How can I make the compilation succeed?</p>



<a name="166204373"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166204373" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Zoxc <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166204373">(May 21 2019 at 19:27)</a>:</h4>
<p>Use <a href="https://github.com/rust-lang/rust/pull/60967" target="_blank" title="https://github.com/rust-lang/rust/pull/60967">https://github.com/rust-lang/rust/pull/60967</a></p>



<a name="166214080"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166214080" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lwshang <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166214080">(May 21 2019 at 21:22)</a>:</h4>
<p>It works! Just got a successful compilation of rustc.</p>
<p>To have two rustc (with/without parallel), should I have two copies of the rust repo with different config.toml? Or I just  locally compile the parallel enabled rustc and compare it with the latest nightly?</p>



<a name="166214248"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166214248" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Zoxc <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166214248">(May 21 2019 at 21:24)</a>:</h4>
<p>Two rustc repos is the safe option, with the same config.toml, except for parallel-compiler</p>



<a name="166260309"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166260309" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166260309">(May 22 2019 at 11:52)</a>:</h4>
<p>Here are the numbers I'm getting (using the compiler from <a href="https://github.com/rust-lang/rust/pull/60967" target="_blank" title="https://github.com/rust-lang/rust/pull/60967">https://github.com/rust-lang/rust/pull/60967</a>):</p>
<ul>
<li>SINGLE-THREADED: 24 min 39 secs</li>
<li>MULTI-THREADED: 25 min 53 secs</li>
</ul>



<a name="166260318"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166260318" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166260318">(May 22 2019 at 11:52)</a>:</h4>
<p>so the parallel compiler is slight slower overall</p>



<a name="166260425"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166260425" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166260425">(May 22 2019 at 11:54)</a>:</h4>
<p>this is for building from scratch FF on a 10 core / 20 thread Xeon processor</p>



<a name="166273100"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273100" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273100">(May 22 2019 at 14:32)</a>:</h4>
<p><span class="user-mention" data-user-id="124287">@mw</span> What are you setting for -Zthreads and -j?</p>



<a name="166273134"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273134" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273134">(May 22 2019 at 14:32)</a>:</h4>
<p>I'd recommend something like -Zthreads=3</p>



<a name="166273372"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273372" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273372">(May 22 2019 at 14:34)</a>:</h4>
<p>no explicit settings</p>



<a name="166273391"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273391" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273391">(May 22 2019 at 14:34)</a>:</h4>
<blockquote>
<p>I'd recommend something like -Zthreads=3</p>
</blockquote>
<p>let me give that a try</p>



<a name="166273398"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273398" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273398">(May 22 2019 at 14:34)</a>:</h4>
<p>ah, that's likely to be bad</p>



<a name="166273426"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273426" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273426">(May 22 2019 at 14:35)</a>:</h4>
<p>the default is .. not great, based on my timing results</p>



<a name="166273479"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273479" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273479">(May 22 2019 at 14:35)</a>:</h4>
<p>i.e., you're hitting the "rising" part of the curve I'd guess</p>



<a name="166273484"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273484" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lwshang <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273484">(May 22 2019 at 14:35)</a>:</h4>
<p>I believe <code>-Zthreads=1</code> is the default. Is that correct?</p>



<a name="166273538"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273538" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273538">(May 22 2019 at 14:36)</a>:</h4>
<p>no, the default is -Zthreads=20 in this case (i.e., number of vCPUs)</p>



<a name="166273629"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273629" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lwshang <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273629">(May 22 2019 at 14:36)</a>:</h4>
<p>Is there a heuristic for setting <code>-Zthreads</code>?</p>



<a name="166273662"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273662" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273662">(May 22 2019 at 14:37)</a>:</h4>
<p>Uncertain -- we'd need more benchmarking across a variety of CPUs and core counts to be able to tell</p>



<a name="166273684"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273684" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273684">(May 22 2019 at 14:37)</a>:</h4>
<p>(i.e., AMD v Intel, could make a difference)</p>



<a name="166273708"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273708" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273708">(May 22 2019 at 14:37)</a>:</h4>
<p>right now it will take the number of logical cores</p>



<a name="166273837"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273837" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273837">(May 22 2019 at 14:38)</a>:</h4>
<p>My theory is that what we want is for rustc's internal threading to be less aggressive than cargo's spawning of rustc processes, but otherwise only constrained to the number of logical cores</p>



<a name="166273857"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273857" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lwshang <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273857">(May 22 2019 at 14:38)</a>:</h4>
<p>As suggest by <span class="user-mention" data-user-id="116122">@simulacrum</span> , current default (num of vCPUs) may not be a good choice.</p>



<a name="166273880"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273880" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273880">(May 22 2019 at 14:39)</a>:</h4>
<p>In speaking to Alex though I believe that's basically impossible with the current implementation of jobserver</p>



<a name="166273907"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166273907" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166273907">(May 22 2019 at 14:39)</a>:</h4>
<p>-Zthreads=3 might be a good "best guess" of how many threads rustc can safely use though</p>



<a name="166276920"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166276920" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166276920">(May 22 2019 at 15:08)</a>:</h4>
<ul>
<li>MULTI-THREADED with -Zthreads=3: 26 min 08 secs</li>
</ul>



<a name="166276967"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166276967" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166276967">(May 22 2019 at 15:09)</a>:</h4>
<p>let's see for debug builds too...</p>



<a name="166277937"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166277937" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Zoxc <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166277937">(May 22 2019 at 15:18)</a>:</h4>
<p>I'd guess 8 threads =P</p>



<a name="166281757"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166281757" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166281757">(May 22 2019 at 15:54)</a>:</h4>
<p>I was using a 8 core / 16 logical core CPU for my determination of -Zthread=3 as more or less optimal</p>



<a name="166281806"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166281806" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166281806">(May 22 2019 at 15:55)</a>:</h4>
<p>so here with more cores it could well be different; plus, I was using a ryzen 1800x so intel might have different performance characteristics</p>



<a name="166369302"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166369302" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166369302">(May 23 2019 at 15:04)</a>:</h4>
<p>here are my numbers for debug builds:</p>
<ul>
<li>single threaded: 16 min 38 secs</li>
<li>threads=3: 18 min 01 secs</li>
<li>threads=10: 17 min 26 secs</li>
</ul>



<a name="166370700"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166370700" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lwshang <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166370700">(May 23 2019 at 15:19)</a>:</h4>
<p>Is your <code>single threaded</code> meaning {<code>parallel-rustc</code> enabled and <code>-Zthreads=1</code>} or {<code>parallel-rustc</code> disabled}?</p>



<a name="166437410"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187679-t-compiler/wg-parallel-rustc/topic/effect%20on%20firefox/near/166437410" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> mw <a href="https://rust-lang.github.io/zulip_archive/stream/187679-t-compiler/wg-parallel-rustc/topic/effect.20on.20firefox.html#166437410">(May 24 2019 at 09:45)</a>:</h4>
<p>single threaded means a compiler compiled with <code>parallel-compiler = false</code></p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>